//
//  CZQCycleModel.m
//  coachmanage
//
//  Created by 众拳科技 on 2018/3/29.
//  Copyright © 2018年 众拳科技. All rights reserved.
//

#import "CZQCycleModel.h"
#define CycleFilePath [[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) lastObject] stringByAppendingPathComponent:[NSString stringWithFormat:@"%@cycle.data",[[NSUserDefaults standardUserDefaults]objectForKey:@"UserID"]]]
@implementation CZQCycleModel

MJCodingImplementation

/**
 *  归档
 */
+ (void)saveBrand:(CZQCycleModel *)cycle;
{
    // 归档
    [NSKeyedArchiver archiveRootObject:cycle toFile:CycleFilePath];
}

/**
 *  读取
 */
+(CZQCycleModel *)cycle;
{
    // 读取帐号
    CZQCycleModel *cycle = [NSKeyedUnarchiver unarchiveObjectWithFile:CycleFilePath];
    
    if (!cycle) {
        
        cycle = [[CZQCycleModel alloc] init];
    }
    
    return cycle;
}

@end

#pragma mark - 评论
@implementation CZQCycleCommentModel

@end
